Python syntax and semantics
part 4/45 · 74.8 KB total
──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
This mantra is deliberately opposed to the Perl and Ruby mantra, "there's more than one way to do it".
Keywords
Python has 35 keywords or reserved words; they cannot be used as identifiers.cite-ref-3[3]cite-ref-4[4]
• and
• as
• assert
• asynccite-ref-keywordin35-6-0[note 1]
• awaitcite-ref-keywordin35-6-1[note 1]
• break
• class
• continue
• def
• del
• elif
• else
• except
• Falsecite-ref-becamekeywordin3-7-0[note 2]
• finally
• for
• from
• global
• if
• import
• in
• is
• lambda
• None
• nonlocalcite-ref-keywordin3-8-0[note 3]
• not
• or
• pass
• raise
• return
• Truecite-ref-becamekeywordin3-7-1[note 2]
• try
• while
• with
• yield
──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────